home *** CD-ROM | disk | FTP | other *** search
/ MacFormat 1994 November / macformat-018.iso / Demos / Extend 3.0 Demo / Extend Demo / Extend Demo.rsrc / HELP_257_ ModL Dialog Items < prev    next >
Encoding:
Text File  |  1994-07-14  |  3.0 KB  |  41 lines

  1. All dialog items have dialog names (for labels, the dialog name is optional). These dialog names are variable names and message names used by the script to interact with the dialog, both to read the data or set the data visible to the user. Some dialog items have titles or text that appear in the dialog.
  2.  
  3. Editable text and parameters can be made “Display only” in the block dialog editor. This allows the user to copy the values, but not change them.
  4.  
  5. Because deleting dialog items can misalign the data in existing models, dialog items can be hidden if the developer wants to “remove” them. This maintains data and variable names to interact with the script, but hides them in the dialog.
  6.  
  7. The dialog items are:
  8.  
  9. • Buttons
  10. User click sends the message name to the script.  Cannot be used as a variable. OK button closes and updates the block’s data from the dialog box.  Its message can be aborted with the ABORT statement to prevent the close, if the data is not entered properly. Cancel just closes the dialog box without updating the block’s data.  Its message cannot be aborted.
  11.  
  12. • CheckBoxes
  13. User click toggles appearance and value between TRUE and FALSE.  Can be used as a message name and variable and has the value TRUE or FALSE (1 or 0).  It can be assigned a value and will update its appearance.
  14.  
  15. • Data Table
  16. A two dimensional table of parameters (similar to a spreadsheet).  The titles of the columns are separated by semicolons.  Titles default to numbers.
  17.  
  18. • Editable Text
  19. A textedit item that can be assigned a string value. This can be read or written to as a string by the script. Editable text items that are two lines or greater create a scroll bar on the item. It can be made “Display only” in the block dialog editor.
  20.  
  21. • Meter
  22. An output-only item that shows a needle in a meter.
  23.  
  24. • Parameters
  25. A textedit item that can be used as a Real variable and can be assigned a value.  A user click also sends the message name to the script message handler. It can be made “Display only” in the block dialog editor.
  26.  
  27. • Radio Buttons
  28. User click affects appearance and value of all in its radio group.  Can be used as a message name and variable and has the value TRUE or FALSE (1 or 0).  It can be assigned a value and will update its group’s appearance.
  29.  
  30. • Slider
  31. A control that resembles a slider on a stereo. You can drag the knob to change a value, or your block can move the knob to show a value.
  32.  
  33. • Static Text (Labels)
  34. Used as titles, but can also be assigned strings or numbers.   The value is always the string entered in the dialog box, so even if you assign a different string to it, its value on the right side of an assignment statement will never change.  (i.e.: If stat is “The value is “, the equation: stat = stat+” $”+5; will show up as: “The value is $5” in the dialog box.
  35.  
  36. • Switch
  37. A switch that resembles a light switch. It has two values, 0 and 1.
  38.  
  39. • Text Tables
  40. A two-dimensional table (similar to a spreadsheet) for holding text.  The titles of the columns are separated by semicolons.  Titles default to numbers.
  41.